<%@ page language="java" import="java.util.*,cn.biwysh.exam.entity.Knowledge" pageEncoding="utf-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";

Knowledge zhishi=new Knowledge();
zhishi.setContent("");
zhishi.setTitle("该知识已被删除");
zhishi.setType(0);
zhishi.setName("");
zhishi.setAddtime(new Date());
if(request.getAttribute("zhishi")!=null){
	zhishi=(Knowledge)request.getAttribute("zhishi");
}
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title><%=zhishi.getTitle() %></title>
    <link href="css/qt/zsdetail.css" rel="stylesheet" type="text/css" />
    <script type="text/javascript" src="script/jquery/jquery-1.5.1.min.js"></script>
    <script type="text/javascript" src="script/jquery/jquery.elastic.source.js"></script>
    <script type="text/javascript">
    $(function() {
    initZYbg();
    if(!window.ActiveXObject){
        $("#textcontest").elastic();
        $("#textcontest").trigger('update');
	    var dheight=$("#textcontest").height();
        if(dheight>500){
        	$("#mainbg").css("height",(150+dheight)+"px");
        	$("#tgTXT").css("height",(160+dheight)+"px");
         }
      }
	$(window).resize(function() {
			    initZYbg();
			   });
});

function initZYbg(){ 
	//alert($(document).width());
       if(document.body.clientWidth<957){
	        $("#mainleft").width(0);
	        $("#mainright").width(0);
	        $("#mainleft").css("display","none");
		    $("#mainright").css("display","none");
        }else{
	       if(!window.ActiveXObject){
		        var wid=($(document).width()-953)/2;
		        $("#mainleft").width(wid);
		        $("#mainright").width(wid);
		        $("#mainleft").css("display","block");
		        $("#mainright").css("display","block");
		    }else{
		        var wid=($(document).width()-974)/2;
		        if(wid>0){
		        	$("#mainleft").width(wid);
			        $("#mainright").width(wid);
			        $("#mainleft").css("display","block");
			        $("#mainright").css("display","block");
		        }
		    }
        }
}
    </script>
  </head>
  
  <body>
    <div id="mainleft"><img src="img/qt/mainleft.jpg" style="width:100%;height:100%;"/></div>
     <div id="main">
      <div id="top">
           <jsp:include page="stitle.jsp" flush="true"></jsp:include>
           <div class="sign clear">
              <div class="signzuo"></div>   
              <div class="signzhong">
                <div class="signshow"><%=zhishi.getName() %></div>
              </div>   
              <div class="signyou"></div>   
           </div>
       </div>
       <div id="tgTXT">
           <div id="mainbg">
              <div style="height: 18px;"></div>
				<div id="stitle"><%=zhishi.getTitle() %></div>
				<div style="height: 15px;border-bottom:dotted 1px #9E9E9E;width:90%;margin:0 auto;"></div>
				<div style="height: 15px;"></div>
				<div style="text-align:center;font-weight:bolder;font-size: 11px;"><%=zhishi.getAddtimestr() %></div>
				<div style="height: 15px;"></div>
				<div id="scontest">
					<textarea id="textcontest" readonly="readonly"
						style="border:0px; min-height:420px;　height:auto;height:420px; width: 75%; background-color: transparent; overflow: visible;font-size: 12px;line-height: 25px;"><%=zhishi.getContent() %></textarea>
				</div>
				<div style="height: 20px;"></div>
				<%if(zhishi.getType()>0){%>
					<div id="fujian" style="height: 20px; text-align:right;margin-right:100px;font-size:12px;">
					  附件：<a id="fjlink" href='download.do?id=<%=zhishi.getId() %>' target='_blank'>点击下载</a>
					</div>
					<div style="height: 20px;"></div>
				<%}%>
           </div>
           <div id="mainbottom"></div>
       </div>
      <div style="height: 10px;"></div>
      <div id="footer">
		  <jsp:include page="footer.jsp" flush="true"></jsp:include>
	   </div>
     </div>
     <div id="mainright"><img src="img/qt/mainright.jpg" style="width:100%;height:100%;"/></div>
  </body>
</html>
